var ManagerGrid = {
	grid:function(option,id){
		var boss = this;
		option.tableClass = "widgets_grid_table_list";
		option.HeadRender = boss.HeadRender;
		option.FootRender = boss.FootRender;
		option.ftClass = "widget_grid_table_foot_page_button";
		var grid = $("#"+id).WidgetGrid(option);
		return grid;
	},
	HeadRender:function(Cloumns,Checkbox){
		var tr = "<tr class='tableHead'>";
		if(Checkbox){
			tr += '<th style="width: 45px;" ><input gridCheckAll="gridCheckAll" type="checkbox"/></th>';
		}
		for(var i = 0; i < Cloumns.length; i++){
			tr += "<th>" + Cloumns[i].text + "</th>";
		}
		tr += "</tr>";
		return tr;
	},	
	FootRender:function(PageIndex,PageCount,RecordCount,PageSize,Cloumns,Checkbox){
		var colspan =Cloumns.length;
		if(Checkbox){
			colspan++;
		}
		var gridFootContent = "<tr class='tableHead'>";
		gridFootContent+='<th class="ftclass" colspan="'+colspan+'">';
		gridFootContent+='<div class="widget_grid_table_foot_page_button">';
		gridFootContent+='<a style="" href="First">首页</a>&nbsp;&nbsp;';
		gridFootContent+='<a href="Prev">上页</a>&nbsp;&nbsp;';
		gridFootContent+='<a href="Next">下页</a>&nbsp;&nbsp;';
		gridFootContent+='<a href="Last">尾页</a>&nbsp;';
		gridFootContent+='</div><div class="widget_grid_table_foot_page_span">';
		gridFootContent+='<span >第'+PageIndex+'页/共'+PageCount+'页</span>&nbsp;|&nbsp;';
		gridFootContent+='<span>记录总数:'+RecordCount+'</span>&nbsp;|&nbsp;';
		gridFootContent+='<span>每页显示:</span>';
		gridFootContent+='<a >'+PageSize+'</a>';
		gridFootContent+='</div>';
		gridFootContent+='</th>	';
		gridFootContent+='</tr>';
		var gridFootTr = $(gridFootContent);
		return gridFootTr;
	}
};